﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using BPM.Entity;
using System.Data.Entity;

namespace BPM.Service
{
	public class ProductAssembleDefinitionService : ServiceBase<ProductAssembleDefinition>
	{
		protected override IQueryable<ProductAssembleDefinition> PrepareToQuery(DbSet<ProductAssembleDefinition> set)
		{
			return base.PrepareToQuery(set)
				.Include(p => p.ItemList);
		}

		protected override void EnableLazyLoadingCore(ProductAssembleDefinition entity)
		{
			base.EnableLazyLoadingCore(entity);

			EnableChildrenLazyLoading(entity.ItemList);
		}
	}
}
